/* Copyright 2018 JDCLOUD.COM

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http:#www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Function OpenAPI


OpenAPI spec version: v1
Contact: 

NOTE: This class is auto generated by the jdcloud code generator program.
*/

#import <Foundation/Foundation.h>
#import <JDCloudOCSDKFunction/FunctionApiModel.h>


@implementation FunctionGetFunctionRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.functionName = functionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    return self;
} 

@end
@implementation FunctionDeleteFunctionRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.functionName = functionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    return self;
} 

@end
@implementation FunctionInvokeRequest
-(id) initWithRegion:(NSString *)regionId
event:(NSString*)event
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.event = event;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
event:(NSString*)event
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.version = version;
    self.event = event;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self event])
    {
        [result setValue:[self event] forKey:@"event"];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self versionName])
    {
        [result setValue:[self versionName] forKey:@"versionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.event = [dictionary objectForKey:@"event"];
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.versionName = [dictionary objectForKey:@"versionName"];
    return self;
} 

@end
@implementation FunctionAsyncInvokeRequest
-(id) initWithRegion:(NSString *)regionId
event:(NSString*)event
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.event = event;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
event:(NSString*)event
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.version = version;
    self.event = event;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self event])
    {
        [result setValue:[self event] forKey:@"event"];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self versionName])
    {
        [result setValue:[self versionName] forKey:@"versionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.event = [dictionary objectForKey:@"event"];
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.versionName = [dictionary objectForKey:@"versionName"];
    return self;
} 

@end
@implementation FunctionCreateVersionRequest
-(id) initWithRegion:(NSString *)regionId
descriptionValue:(NSString*)descriptionValue
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.descriptionValue = descriptionValue;
    self.functionName = functionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
descriptionValue:(NSString*)descriptionValue
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.version = version;
    self.descriptionValue = descriptionValue;
    self.functionName = functionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self descriptionValue])
    {
        [result setValue:[self descriptionValue] forKey:@"description"];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.descriptionValue = [dictionary objectForKey:@"description"];
    self.functionName = [dictionary objectForKey:@"functionName"];
    return self;
} 

@end
@implementation FunctionGetVersionRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self versionName])
    {
        [result setValue:[self versionName] forKey:@"versionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.versionName = [dictionary objectForKey:@"versionName"];
    return self;
} 

@end
@implementation FunctionDeleteVersionRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self versionName])
    {
        [result setValue:[self versionName] forKey:@"versionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.versionName = [dictionary objectForKey:@"versionName"];
    return self;
} 

@end
@implementation FunctionListVersionRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.functionName = functionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    return self;
} 

@end
@implementation FunctionGetTriggerRequest
-(id) initWithRegion:(NSString *)regionId
triggerId:(NSString*)triggerId
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.triggerId = triggerId;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
triggerId:(NSString*)triggerId
functionName:(NSString*)functionName
versionName:(NSString*)versionName { 
    self.regionId = regionId;
    self.version = version;
    self.triggerId = triggerId;
    self.functionName = functionName;
    self.versionName = versionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self triggerId])
    {
        [result setValue:[self triggerId] forKey:@"triggerId"];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self versionName])
    {
        [result setValue:[self versionName] forKey:@"versionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.triggerId = [dictionary objectForKey:@"triggerId"];
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.versionName = [dictionary objectForKey:@"versionName"];
    return self;
} 

@end
@implementation FunctionDeleteAliasRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName
aliasName:(NSString*)aliasName { 
    self.regionId = regionId;
    self.functionName = functionName;
    self.aliasName = aliasName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName
aliasName:(NSString*)aliasName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    self.aliasName = aliasName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self aliasName])
    {
        [result setValue:[self aliasName] forKey:@"aliasName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.aliasName = [dictionary objectForKey:@"aliasName"];
    return self;
} 

@end
@implementation FunctionListAliasRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.functionName = functionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    return self;
} 

@end
@implementation FunctionGetAliasRequest
-(id) initWithRegion:(NSString *)regionId
functionName:(NSString*)functionName
aliasName:(NSString*)aliasName { 
    self.regionId = regionId;
    self.functionName = functionName;
    self.aliasName = aliasName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
functionName:(NSString*)functionName
aliasName:(NSString*)aliasName { 
    self.regionId = regionId;
    self.version = version;
    self.functionName = functionName;
    self.aliasName = aliasName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self aliasName])
    {
        [result setValue:[self aliasName] forKey:@"aliasName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.aliasName = [dictionary objectForKey:@"aliasName"];
    return self;
} 

@end
@implementation FunctionUpdateAliasRequest
-(id) initWithRegion:(NSString *)regionId
descriptionValue:(NSString*)descriptionValue
functionName:(NSString*)functionName
aliasName:(NSString*)aliasName { 
    self.regionId = regionId;
    self.descriptionValue = descriptionValue;
    self.functionName = functionName;
    self.aliasName = aliasName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
descriptionValue:(NSString*)descriptionValue
functionName:(NSString*)functionName
aliasName:(NSString*)aliasName { 
    self.regionId = regionId;
    self.version = version;
    self.descriptionValue = descriptionValue;
    self.functionName = functionName;
    self.aliasName = aliasName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self descriptionValue])
    {
        [result setValue:[self descriptionValue] forKey:@"description"];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    if([self aliasName])
    {
        [result setValue:[self aliasName] forKey:@"aliasName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.descriptionValue = [dictionary objectForKey:@"description"];
    self.functionName = [dictionary objectForKey:@"functionName"];
    self.aliasName = [dictionary objectForKey:@"aliasName"];
    return self;
} 

@end
@implementation FunctionCreateAliasRequest
-(id) initWithRegion:(NSString *)regionId
aliasName:(NSString*)aliasName
descriptionValue:(NSString*)descriptionValue
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.aliasName = aliasName;
    self.descriptionValue = descriptionValue;
    self.functionName = functionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
aliasName:(NSString*)aliasName
descriptionValue:(NSString*)descriptionValue
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.version = version;
    self.aliasName = aliasName;
    self.descriptionValue = descriptionValue;
    self.functionName = functionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self aliasName])
    {
        [result setValue:[self aliasName] forKey:@"aliasName"];
    }
    if([self descriptionValue])
    {
        [result setValue:[self descriptionValue] forKey:@"description"];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.aliasName = [dictionary objectForKey:@"aliasName"];
    self.descriptionValue = [dictionary objectForKey:@"description"];
    self.functionName = [dictionary objectForKey:@"functionName"];
    return self;
} 

@end
@implementation FunctionUpdateFunctionResult
-(id) initWithData:(Function*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Function alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionUpdateFunctionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionUpdateFunctionResult* result = [[FunctionUpdateFunctionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionUpdateFunctionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionUpdateFunctionRequest
-(id) initWithRegion:(NSString *)regionId
descriptionValue:(NSString*)descriptionValue
entrance:(NSString*)entrance
memory:(NSNumber*)memory
runTime:(NSString*)runTime
overTime:(NSNumber*)overTime
code:(Code*)code
environment:(Env*)environment
logSetId:(NSString*)logSetId
logTopicId:(NSString*)logTopicId
vpcId:(NSString*)vpcId
subnetId:(NSString*)subnetId
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.descriptionValue = descriptionValue;
    self.entrance = entrance;
    self.memory = memory;
    self.runTime = runTime;
    self.overTime = overTime;
    self.code = code;
    self.environment = environment;
    self.logSetId = logSetId;
    self.logTopicId = logTopicId;
    self.vpcId = vpcId;
    self.subnetId = subnetId;
    self.functionName = functionName;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
descriptionValue:(NSString*)descriptionValue
entrance:(NSString*)entrance
memory:(NSNumber*)memory
runTime:(NSString*)runTime
overTime:(NSNumber*)overTime
code:(Code*)code
environment:(Env*)environment
logSetId:(NSString*)logSetId
logTopicId:(NSString*)logTopicId
vpcId:(NSString*)vpcId
subnetId:(NSString*)subnetId
functionName:(NSString*)functionName { 
    self.regionId = regionId;
    self.version = version;
    self.descriptionValue = descriptionValue;
    self.entrance = entrance;
    self.memory = memory;
    self.runTime = runTime;
    self.overTime = overTime;
    self.code = code;
    self.environment = environment;
    self.logSetId = logSetId;
    self.logTopicId = logTopicId;
    self.vpcId = vpcId;
    self.subnetId = subnetId;
    self.functionName = functionName;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self descriptionValue])
    {
        [result setValue:[self descriptionValue] forKey:@"description"];
    }
    if([self entrance])
    {
        [result setValue:[self entrance] forKey:@"entrance"];
    }
    if([self memory])
    {
        [result setValue:[self memory] forKey:@"memory"];
    }
    if([self runTime])
    {
        [result setValue:[self runTime] forKey:@"runTime"];
    }
    if([self overTime])
    {
        [result setValue:[self overTime] forKey:@"overTime"];
    }
    if([self code])
    {
        [result setValue:[[self code] dictionary]forKey:@"code"];
    }
    if([self environment])
    {
        [result setValue:[[self environment] dictionary]forKey:@"environment"];
    }
    if([self logSetId])
    {
        [result setValue:[self logSetId] forKey:@"logSetId"];
    }
    if([self logTopicId])
    {
        [result setValue:[self logTopicId] forKey:@"logTopicId"];
    }
    if([self vpcId])
    {
        [result setValue:[self vpcId] forKey:@"vpcId"];
    }
    if([self subnetId])
    {
        [result setValue:[self subnetId] forKey:@"subnetId"];
    }
    if([self functionName])
    {
        [result setValue:[self functionName] forKey:@"functionName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.descriptionValue = [dictionary objectForKey:@"description"];
    self.entrance = [dictionary objectForKey:@"entrance"];
    self.memory = [dictionary objectForKey:@"memory"];
    self.runTime = [dictionary objectForKey:@"runTime"];
    self.overTime = [dictionary objectForKey:@"overTime"];
    self.code = [[Code alloc]initWithDic:[dictionary objectForKey:@"code"]];
    self.environment = [[Env alloc]initWithDic:[dictionary objectForKey:@"environment"]];
    self.logSetId = [dictionary objectForKey:@"logSetId"];
    self.logTopicId = [dictionary objectForKey:@"logTopicId"];
    self.vpcId = [dictionary objectForKey:@"vpcId"];
    self.subnetId = [dictionary objectForKey:@"subnetId"];
    self.functionName = [dictionary objectForKey:@"functionName"];
    return self;
} 

@end
@implementation FunctionInvokeResultResult
-(id) initWithData:(FunctionInvokeResult*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[FunctionInvokeResult alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
@implementation FunctionGetFunctionResult
-(id) initWithData:(Function*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Function alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionGetFunctionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionGetFunctionResult* result = [[FunctionGetFunctionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionGetFunctionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionAsyncInvokeResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation FunctionAsyncInvokeResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionAsyncInvokeResult* result = [[FunctionAsyncInvokeResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionAsyncInvokeResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionListFunctionRequest
-(id) initWithRegion:(NSString *)regionId
listAll:(NSNumber*)listAll
pageNumber:(NSNumber*)pageNumber
pageSize:(NSNumber*)pageSize
filters:(NSArray<Filter*>*)filters { 
    self.regionId = regionId;
    self.listAll = listAll;
    self.pageNumber = pageNumber;
    self.pageSize = pageSize;
    self.filters = filters;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
listAll:(NSNumber*)listAll
pageNumber:(NSNumber*)pageNumber
pageSize:(NSNumber*)pageSize
filters:(NSArray<Filter*>*)filters { 
    self.regionId = regionId;
    self.version = version;
    self.listAll = listAll;
    self.pageNumber = pageNumber;
    self.pageSize = pageSize;
    self.filters = filters;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self listAll])
    {
        [result setValue:[self listAll] forKey:@"listAll"];
    }
    if([self pageNumber])
    {
        [result setValue:[self pageNumber] forKey:@"pageNumber"];
    }
    if([self pageSize])
    {
        [result setValue:[self pageSize] forKey:@"pageSize"];
    }
    if([self filters])
    {
            NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
            for (int i =0 ; i< [[self filters] count]; i++) {
            Filter* item = [[self filters] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"filters"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.listAll = [dictionary objectForKey:@"listAll"];
    self.pageNumber = [dictionary objectForKey:@"pageNumber"];
    self.pageSize = [dictionary objectForKey:@"pageSize"];
    NSArray* filtersArray = [dictionary objectForKey:@"filters"];
    if(filtersArray&&![filtersArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [filtersArray count];i++)
        {
        Filter* item = [[Filter alloc]initWithDic:[filtersArray objectAtIndex:i]];
            if(item)
            {
            [propertyArray addObject:item];
            }
        }
        self.filters = propertyArray;
    }
    return self;
} 

@end
@implementation FunctionListFunctionResult
-(id) initWithData:(ListFunctionResult*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[ListFunctionResult alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionListFunctionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionListFunctionResult* result = [[FunctionListFunctionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionListFunctionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionCreateFunctionResult
-(id) initWithData:(Function*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Function alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
@implementation FunctionCreateFunctionRequest
-(id) initWithRegion:(NSString *)regionId
name:(NSString*)name
descriptionValue:(NSString*)descriptionValue
entrance:(NSString*)entrance
memory:(NSNumber*)memory
runTime:(NSString*)runTime
overTime:(NSNumber*)overTime
code:(Code*)code
environment:(Env*)environment
logSetId:(NSString*)logSetId
logTopicId:(NSString*)logTopicId
vpcId:(NSString*)vpcId
subnetId:(NSString*)subnetId { 
    self.regionId = regionId;
    self.name = name;
    self.descriptionValue = descriptionValue;
    self.entrance = entrance;
    self.memory = memory;
    self.runTime = runTime;
    self.overTime = overTime;
    self.code = code;
    self.environment = environment;
    self.logSetId = logSetId;
    self.logTopicId = logTopicId;
    self.vpcId = vpcId;
    self.subnetId = subnetId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
name:(NSString*)name
descriptionValue:(NSString*)descriptionValue
entrance:(NSString*)entrance
memory:(NSNumber*)memory
runTime:(NSString*)runTime
overTime:(NSNumber*)overTime
code:(Code*)code
environment:(Env*)environment
logSetId:(NSString*)logSetId
logTopicId:(NSString*)logTopicId
vpcId:(NSString*)vpcId
subnetId:(NSString*)subnetId { 
    self.regionId = regionId;
    self.version = version;
    self.name = name;
    self.descriptionValue = descriptionValue;
    self.entrance = entrance;
    self.memory = memory;
    self.runTime = runTime;
    self.overTime = overTime;
    self.code = code;
    self.environment = environment;
    self.logSetId = logSetId;
    self.logTopicId = logTopicId;
    self.vpcId = vpcId;
    self.subnetId = subnetId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self descriptionValue])
    {
        [result setValue:[self descriptionValue] forKey:@"description"];
    }
    if([self entrance])
    {
        [result setValue:[self entrance] forKey:@"entrance"];
    }
    if([self memory])
    {
        [result setValue:[self memory] forKey:@"memory"];
    }
    if([self runTime])
    {
        [result setValue:[self runTime] forKey:@"runTime"];
    }
    if([self overTime])
    {
        [result setValue:[self overTime] forKey:@"overTime"];
    }
    if([self code])
    {
        [result setValue:[[self code] dictionary]forKey:@"code"];
    }
    if([self environment])
    {
        [result setValue:[[self environment] dictionary]forKey:@"environment"];
    }
    if([self logSetId])
    {
        [result setValue:[self logSetId] forKey:@"logSetId"];
    }
    if([self logTopicId])
    {
        [result setValue:[self logTopicId] forKey:@"logTopicId"];
    }
    if([self vpcId])
    {
        [result setValue:[self vpcId] forKey:@"vpcId"];
    }
    if([self subnetId])
    {
        [result setValue:[self subnetId] forKey:@"subnetId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.name = [dictionary objectForKey:@"name"];
    self.descriptionValue = [dictionary objectForKey:@"description"];
    self.entrance = [dictionary objectForKey:@"entrance"];
    self.memory = [dictionary objectForKey:@"memory"];
    self.runTime = [dictionary objectForKey:@"runTime"];
    self.overTime = [dictionary objectForKey:@"overTime"];
    self.code = [[Code alloc]initWithDic:[dictionary objectForKey:@"code"]];
    self.environment = [[Env alloc]initWithDic:[dictionary objectForKey:@"environment"]];
    self.logSetId = [dictionary objectForKey:@"logSetId"];
    self.logTopicId = [dictionary objectForKey:@"logTopicId"];
    self.vpcId = [dictionary objectForKey:@"vpcId"];
    self.subnetId = [dictionary objectForKey:@"subnetId"];
    return self;
} 

@end
@implementation FunctionDeleteFunctionResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation FunctionDeleteFunctionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionDeleteFunctionResult* result = [[FunctionDeleteFunctionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionDeleteFunctionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation FunctionCreateFunctionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionCreateFunctionResult* result = [[FunctionCreateFunctionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionCreateFunctionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation FunctionInvokeResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionInvokeResult* result = [[FunctionInvokeResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionInvokeResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionListVersionResult
-(id) initWithData:(NSArray<FunctionSpec*>*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
            NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
            for (int i =0 ; i< [[self data] count]; i++) {
            FunctionSpec* item = [[self data] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    NSArray* dataArray = [dictionary objectForKey:@"data"];
    if(dataArray&&![dataArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [dataArray count];i++)
        {
        FunctionSpec* item = [[FunctionSpec alloc]initWithDic:[dataArray objectAtIndex:i]];
            if(item)
            {
            [propertyArray addObject:item];
            }
        }
        self.data = propertyArray;
    }
    return self;
} 

@end
@implementation FunctionDeleteVersionResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation FunctionDeleteVersionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionDeleteVersionResult* result = [[FunctionDeleteVersionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionDeleteVersionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionGetVersionResult
-(id) initWithData:(Function*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Function alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionGetVersionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionGetVersionResult* result = [[FunctionGetVersionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionGetVersionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation FunctionListVersionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionListVersionResult* result = [[FunctionListVersionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionListVersionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionCreateVersionResult
-(id) initWithData:(Function*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Function alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionCreateVersionResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionCreateVersionResult* result = [[FunctionCreateVersionResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionCreateVersionResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionGetTriggerResult
-(id) initWithData:(Trigger*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Trigger alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionGetTriggerResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionGetTriggerResult* result = [[FunctionGetTriggerResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionGetTriggerResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionDeleteAliasResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
@implementation FunctionUpdateAliasResult
-(id) initWithData:(Alias*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Alias alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
@implementation FunctionCreateAliasResult
-(id) initWithData:(Alias*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Alias alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionCreateAliasResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionCreateAliasResult* result = [[FunctionCreateAliasResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionCreateAliasResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation FunctionDeleteAliasResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionDeleteAliasResult* result = [[FunctionDeleteAliasResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionDeleteAliasResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation FunctionUpdateAliasResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionUpdateAliasResult* result = [[FunctionUpdateAliasResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionUpdateAliasResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionGetAliasResult
-(id) initWithData:(Alias*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.data = [[Alias alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
  
@implementation FunctionGetAliasResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionGetAliasResult* result = [[FunctionGetAliasResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionGetAliasResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation FunctionListAliasResult
-(id) initWithData:(NSArray<Alias*>*) data { 
    self.data = data;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self data])
    {
            NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
            for (int i =0 ; i< [[self data] count]; i++) {
            Alias* item = [[self data] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    NSArray* dataArray = [dictionary objectForKey:@"data"];
    if(dataArray&&![dataArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [dataArray count];i++)
        {
        Alias* item = [[Alias alloc]initWithDic:[dataArray objectAtIndex:i]];
            if(item)
            {
            [propertyArray addObject:item];
            }
        }
        self.data = propertyArray;
    }
    return self;
} 

@end
  
@implementation FunctionListAliasResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
FunctionListAliasResult* result = [[FunctionListAliasResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(FunctionListAliasResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
 
